package com.allwees.bs.c.module.product.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.allwees.bs.core.model.product.entity.SkuModel;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;

import javax.persistence.Entity;
import javax.persistence.Table;
import javax.persistence.Transient;

@Data
@EqualsAndHashCode(callSuper = true)
@NoArgsConstructor
@Entity()
@Table(name = "prod_sku")
@TableName("prod_sku")
public class SkuEntity extends SkuModel {
    private static final long serialVersionUID = -523374426420494894L;

    @Transient
    @TableField(exist=false)
    @JsonInclude(JsonInclude.Include.NON_NULL)
    private int buyQuantity;
}
